package unigis;

public class GeometryGenerator {
	
	public static void main(String[] args) {
		Geometry mygeom = new Geometry(args);
		System.out.println(mygeom.constructWKT());
	}
}

class Geometry {
	
	private String[] vertices;
	public Geometry(String[] vertices) {
		this.vertices = vertices;
	}
	
	public String constructWKT() {
		String wkt = "LINESTRING(";
		for (int i = 0; i < vertices.length-1; i = i + 2) {
			wkt += vertices[i] + " " + vertices[i+1] + ",";
		}
		wkt = wkt.substring(0, wkt.length()-1);
		wkt += ")";
		return wkt;
	}
}
